#ifndef CGOBANGDOC_H_
#define CGOBANGDOC_H_

enum BoardState{ERROR,EMPTY,BLACK,WHITE};
enum GameMode{P2P,P2P_NETWORT,P2AI};
enum GameResult{BLACK_WIN,WHITE_WIN,DRAW,NO_RESULT};

class CGobangDoc{
public:
	GameResult CheckResult(int x,int y);
	bool CheckAvailable(int x,int y);
	bool InitializeChessBoard();
	BoardState GetBoardState(int x,int y);
	bool SetBoardState(int x,int y);
	bool SetGameMode(GameMode);
	GameMode GetGameMode();
	const CArray<CPoint,CPoint&>& GetPlayStack();
	bool OnNewDocument();
	void Serialize(CArchive&);
	bool CheckBoarder(int x,int y);
	int GetBoardIndex(int x,int y);
	bool ChangeBoardSize(int x);
	bool IsBlackChess();
	CPoint UndoChess();
	CPoint RedoChess();
	CPoint GetLastMove();
};

#endif
